{* FILTERS *}

{literal}
<script language="javascript">
	function updateRequest(id,action) {
		var forma = document.getElementById("list_form");
		forma.op.value=action;
		forma.id.value=id;
		forma.submit();
	}
</script>
{/literal}

<center>
<form method="post" id="lang_form">
	<input type="hidden" name="flowid" id="flowid" value="{$flowid}">
	<input type="hidden" name="action" id="action" value="languages">
	<input type="hidden" name="op" id="op" value="add">
	 <table width="100%" cellpadding="0" cellspacing="0">
	   <tr>
		 <td>&nbsp;{$lang.lang}</td>
		 <td><input type="text" size="6" maxlength="5" name="id" id="id" class="txt"></td>
		</tr>
			 <td align="right" colspan="2">
				 {include file="button.tpl" name=$lang.new action="processForm('lang_form')"}
			 </td>
	   </tr>
	 </table>	
</form>
</center>


<center>
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0">

	<thead>
		<tr>
			<th>{$lang.lang}</th>
			<th>&nbsp;</th>
		</tr>
	</thead>

	{* TABLE BODY - DYNAMIC *}
	<tbody>
		{assign var="rowclass" value="uneven"}
		{foreach from=$list item=row}
			<tr class="{$rowclass}">
				<td>{$row->id}</td>
				<td>
					<span onclick="if (confirm('{$lang.confirmdelete}')) {ldelim} updateRequest('{$row->id}','remove') {rdelim}" class="link">{$lang.remove}</span>
				</td> 
			</tr>
			{if $rowclass eq 'even'}
				{assign var="rowclass" value="uneven"}
			{else}
				{assign var="rowclass" value="even"}
			{/if}
		{/foreach}

	</tbody>

</table>
<center>

<form method="post" id="list_form">
	<input type="hidden" name="flowid" id="flowid" value="{$flowid}">
	<input type="hidden" name="action" id="action" value="languages">
	<input type="hidden" name="op" id="op" value="">	
	<input type="hidden" name="id" id="id" value="">
</form>